#ifndef USERINFO_H
#define USERINFO_H

#include <QDialog>
#include <QTcpServer>
#include <QTcpSocket>
#include <QMessageBox>
#include <QFileDialog>
#include "msg.h"

namespace Ui {
class UserInfo;
}

class UserInfo : public QDialog
{
    Q_OBJECT

public:
    explicit UserInfo(QWidget *parent = 0);
    UserInfo( QTcpSocket * s ,QString name,QWidget *parent = 0);
    void setInfo( QTcpSocket * s,QString u);
    ~UserInfo();

private:
    Ui::UserInfo *ui;
    QTcpSocket* socket = NULL;
    QString readPath="";
    QString username;

private slots:
    void DealAnswer();
    void SendUserInfo();

    void ChoosePic();
};

#endif // USERINFO_H
